// @ts-ignore
/* eslint-disable */
import { request } from '@umijs/max';

/** 管理员添加合法的成果 管理员添加合法的成果 POST /valid-awards/addValidAwards */
export async function postValidAwardsAddValidAwards(
  body: API.AddValidAwardsDTO,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseValidAwards>('/valid-awards/addValidAwards', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** 管理员删除合法的成果 管理员删除合法的成果 GET /valid-awards/deleteValidAwards */
export async function getValidAwardsDeleteValidAwards(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.getValidAwardsDeleteValidAwardsParams,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseBoolean>('/valid-awards/deleteValidAwards', {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  });
}

/** 获取合法的成果列表（模糊查询） 管理员获取合法的成果列表（模糊查询） POST /valid-awards/getValidAwards */
export async function postValidAwardsGetValidAwards(
  body: API.GetValidAwardsListDTO,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponsePageVOValidAwards>(
    '/valid-awards/getValidAwards',
    {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json',
      },
      data: body,
      ...(options || {}),
    },
  );
}

/** 获取合法的成果详情 获取合法的成果详情 GET /valid-awards/getValidAwardsById */
export async function getValidAwardsGetValidAwardsById(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.getValidAwardsGetValidAwardsByIdParams,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseGetValidAwardDetailVO>(
    '/valid-awards/getValidAwardsById',
    {
      method: 'GET',
      params: {
        ...params,
      },
      ...(options || {}),
    },
  );
}

/** 管理员修改合法的成果 管理员修改合法的成果 POST /valid-awards/updateValidAwards */
export async function postValidAwardsUpdateValidAwards(
  body: API.UpdateValidAwardsDTO,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseValidAwards>(
    '/valid-awards/updateValidAwards',
    {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json',
      },
      data: body,
      ...(options || {}),
    },
  );
}
